<template>
  <div class="newList">
    <div class="newList-title" v-if="title">
      <span class="newList-title-p1 reset">{{title.title}}</span>
      <span class="newList-title-p2" @click="moreNews(title)">
        more
        <van-icon name="arrow" />
      </span>
    </div>
    <ul class="news-box">
      <li class="news-item" v-for="(i,index) in list" :key="index">
        <newsItem :i="i"></newsItem>
      </li>
    </ul>
  </div>
</template>
<script type="text/ecmascript-6">
import newsItem from "./newstLi";
export default {
  props: ["title", "list"],
  components: {
    newsItem
  },
  methods: {
    moreNews(title) {
      let query = {};
      query.channel = title.name;
      query.title = title.title + " " + "Reports";
      this.$router.push({ path: "reportpart", query: query });
    },
    newsDetail(i) {
 
      this.$router.push({ name: "newsDetails", query: i });
    }
  }
};
</script>

<style scoped lang="less">
@import url("./news.less");
</style>
